<%@page import="org.swim.web.servlet.consts.Action"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8" import="org.swim.web.utils.*"
	import="org.swim.remote.entities.*"%>
<%@page import="org.swim.remote.entities.IFriendship.Status"%>
<%@page import="org.apache.commons.lang.WordUtils"%>
<%@page import="java.util.List"%>
<%@page import="java.util.ArrayList"%>
<%
	IUser other = (IUser) request.getAttribute("user");
	IUser me = (IUser) request.getAttribute("owner");
%>
<div class="user-item medium-text ui-corner-all">
	<div class="alert alert-info pull-right">
		Feedback:
		<%=other.getFeedbackAvgVal()%></div>
	<h4>
		<a href="<%=SwimConst.Url.Servlet.PROFILE%>?who=<%=other.getId()%>"><%=SwimUtils.capitalizaName(other.getFullName()
					.toLowerCase())%></a> <br />

		<%
			if (SwimUtils.areFriends(me, other)) {
		%>
		<a href="mailto:<%=other.getEmail()%>"> <%=other.getEmail()%></a>
		<%
			}
		%>
		<br />
	</h4>
	<p class="">
		<%
			List<IAbility> abilities = new ArrayList<IAbility>(
					other.getAbilitiesSet());
			IAbility ability;
			String name;
			String cssClass = "";
			for (int j = 0; j < abilities.size(); j++) {
				ability = abilities.get(j);
				name = SwimUtils.capitalizeFirstChar(ability.getName()
						.toLowerCase());
				if (ability.getStatus() == IAbility.Status.CONFIRMED) {
					cssClass = "btn-success";
		%>

		<input name="abilities" type="hidden"
			value="<%=SwimUtils.capitalizeFirstChar(ability.getName()
							.toLowerCase())%>">
		<a class="btn <%=cssClass%> disabled" style="margin-top: 5px"><%=name%></a>
		<%
			}
			}
		%>
	</p>
	<%@include file="userbar.jsp"%>
</div>